package com.thirdDay;

public class Demo12 {
    public static void main(String[] args) {
        test02();
        test01();
    }

    private static void test02() {
        String s1 = "abc";
        String s2 = "ab";
        String s3 = s2 + "c";
        System.out.println(s1 == s3); // false
    }

    private static void test01() {
        String s1 = "abc";
        String s2 = "a" + "b" + "c";
        System.out.println(s1 == s2); // true
    }
}
